home *** CD-ROM | disk | FTP | other *** search
- /* demopop.c - used for testing TCHK popup menus */
-
- #include <menuhk.h>
- #include <video.h>
- #include <color.h>
- #include <howard.h>
- #include <stdio.h>
- #include <string.h>
-
- void main()
- {
- extern int _argc, popuperrno;
- char *cmd[]={""," Protocol",""," Xmodem"," Ymodem"," Zmodem"," Disabled"," Other",""};
- char cmdflag[] = { 2,2,2,0,0,0,1,0,2 };
- char fr[] = {'╔','═','╗','║','╝','═','╚','║','\0','╣','╠'};
- int k, cmdkey[] = { -1,-1,-1, 1,1,1, -1, -1, -1};
- struct popup_header *ph;
-
- ph = popup_alloc(8,4,25,14,fr,"Upload",_argc-1,cmd,cmdkey,cmdflag,
- LWHITE|B_BLUE, LRED, YELLOW, LRED, LBLUE|B_WHITE, CYAN,
- BLACK|B_CYAN, LGREEN, 1, CASEINDEP|ERASEMENU|WRAPAROUND|ESCQUIT);
- if (ph == NULL)
- printf("ph == NULL\n");
- else {
- do {
- k = popup_get(ph);
- gotohv(60,22);
- printf("k = %2d",k);
- } while (k != 0);
- popup_free(ph);
- }
- }